Composites

<#5192#> A contact which is the parent of another contact is known as a <#2315#>composite<#2315#>. A composite may be the parent of another composite, leading to a tree-structured contact hierarchy. Contact A is said to be an <#2317#>ancestor<#2317#> of contact B (its <#2319#>descendant<#2319#>) when A is B's parent or an ancestor of B's parent.

A composite represents a set of contacts which can be manipulated (positioned, presented, etc.) as a unit. A composite is useful whenever several contacts act in concert to provide a single component of the application's user interface. Typical examples include ``control panels'' and ``dialog boxes'' --- groups of contacts that are presented together and are used to make related adjustments to application data. In some cases, operations on one member of such a structure may change the appearance of another. The composite is the mechanism which allows the operations of its members to be coordinated.

The fundamental aspects of the contact parent-child relationship are the same as those of the window hierarchy defined by the X Window System. In addition, a composite furnishes geometry management and focus management services for its children.

A composite is an instance of the <#2321#>composite<#2321#> class, a subclass of the basic <#2322#>contact<#2322#> class.

<#4692#> <#4399#><#2323#>composite Class<#2323#><#4399#>

#tex2html_wrap_inline10196#
<#4692#>

#tex2html_wrap_inline10198#

#tex2html_wrap_inline10199#

#tex2html_wrap_inline10200#

<#4693#> <#4404#><#2357#>add-child Method, composite<#2357#><#4404#>

#tex2html_wrap_inline10201#
<#4693#>

#tex2html_wrap_inline10204#

#tex2html_wrap_inline10205#

<#4408#><#2383#>delete-child Method, composite<#2383#><#4408#>

#tex2html_wrap_inline10206#

#tex2html_wrap_inline10207#

<#4694#> <#4411#><#2402#>(setf contact-parent) Method, contact<#2402#><#4411#>

#tex2html_wrap_inline10208#
<#4694#>

#tex2html_wrap_inline10211#

=0 <#5202#>=0 <#5206#>